package com.cndw.kungfu.socket;

import org.jboss.netty.channel.ChannelPipeline;
import org.jboss.netty.channel.ChannelPipelineFactory;
import org.jboss.netty.channel.Channels;

/**
 * pipelineFactory
 * 
 * 
 * @author <a href="mailto:whz-work@163.com">汪洪州</a>
 * 
 * @since 1.0 Create on 2011-5-18
 */
public class ClientPipelineFactory implements ChannelPipelineFactory {

	@Override
	public ChannelPipeline getPipeline() throws Exception {

		ChannelPipeline channelPipeline = Channels.pipeline();
		channelPipeline.addLast("framer", new ClientFrameDecoder());
		channelPipeline.addLast("handler", new ClientHandler());

		return channelPipeline;
	}

}
